import request from '@/utils/request'
import qs from 'qs'

export const ThealthplanQueryAll = () =>
    request({
        url: '/tjthealthplan/all',
        method: 'get'
    })
    export const ThealthplanTypeQueryAll = () =>
    request({
        url: '/tjthealthplan/allType',
        method: 'get'
    })
    export const ThealthplanQueryLike = (search) =>
    request({
        url: '/tjthealthplan',
        method: 'get',
        params:{
          title:search.title,
          typeId:search.typeId
        }
    })

    export const ThealthplanAdd = (THealthPlan) =>
    request({
        url: '/thealthplan',
        method: 'post',
        data:THealthPlan
    })

    export const ThealthplanDel = (id) =>
    request({
        url: '/thealthplan/'+id,
        method: 'delete',
    })

    export const ThealthplanqueryById = (id) =>
    request({
        url: '/thealthplan/'+id,
        method: 'get',
    })
    export const ThealthplanUpd = (THealthPlan) =>
    request({
        url: '/thealthplan',
        method: 'put',
        data:THealthPlan
    })
